package com.itheima.heima.info.manager.system.controller;

import com.itheima.heima.info.manager.system.domain.Student;
import com.itheima.heima.info.manager.system.service.StudentService;

import java.util.Scanner;

/*
学生交互类
与学生 键盘录入  输出的代码
应该在这个类中
 */
public class OtherStudentController extends BaseStudentController{
    //键盘录入
    private Scanner sc = new Scanner(System.in);

    @Override
    public Student getStudentInfo(String sid) {
        System.out.println("请输入姓名");
        String name = sc.next();
        System.out.println("请输入年龄");
        int age = sc.nextInt();
        System.out.println("请输入生日");
        String birthday = sc.next();
        Student student = new Student(sid, name, age, birthday);
        return student;
    }
}
